#!/usr/bin/env python
# ConInput con module
# V0.2
import file_con
def ConInput():

    con_file = file_con.GetFile() #get the file
    con_len = len(con_file) # get the length of the list

    base_index = 0 #list starting point
x    con_in = raw_input("SAY: ") #user input
    con_in = con_in+"\n" #adding \n to match the list format ("hi\n")
    con_in.lower() #lowercasing the string
    #print con_in ##
    #print con_file[base_index] ##
    
    if con_in == con_file[base_index]:
		base_index += 1
		print con_file[base_index]
    
    while con_in != con_file[base_index]:
		base_index += 1
		
		if con_in == con_file[base_index]:
			base_index += 1
			print con_file[base_index]
			break
		if base_index >- con_len:
			print "WORD INVALID"
			break




        



if __name__ == "__main__":
    ConInput()
